﻿<div id="cache_popup" ></div>

<div id="popup" class="{{config.typePopup}}">
	<div class="btn_fermer_popup" ng-click="fermerPopup()" ng-show="config.btn_fermer"></div>
	<div id="message_popup" ng-show="config.message != ''" ng-bind-html="config.message"></div>

	<!-- Si Popup Mise à jour -->	
	<div class="progress progress-striped active" ng-show="config.typePopup == 'miseajour'">
	  <div class="progress-bar"  role="progressbar" style="width:{{pourcentage}}" ng-class="{erreur_mise_a_jour: erreurMiseAJour}"></div>
	</div>
	
	<div id="bloc_boutons_popup"  ng-show="config.btn_oui_non">
		<div id="btn_oui" class="btn_appli" ng-click="reponsePopup(1,config.fonctionReponse)">Oui</div>
		<div id="btn_non" class="btn_appli" ng-click="reponsePopup(0,config.fonctionReponse)">Non</div>
	</div>
</div> 

<script>
$(function(){
	function calculerPositionPopup(){	
		$("#popup").css("left",($("html").width()/2)-(($("#popup").width()+30)/2));
		$("#popup").css("top",($("html").height()/2)-(($("#popup").height()+30)/2));
	}
	
	$( window ).resize(function() {
			calculerPositionPopup();
	});

	calculerPositionPopup();
	});
</script>